pkgname=vdr-subtitles
pkgver=0.5.0
pkgrel=1
arch=('i686')
pkgdesc="DVB subtitles plugin for VDR"
url="http://virtanen.org/vdr/subtitles/"
license=('GPL')
depends=('vdr' 'gcc')
source=(http://virtanen.org/vdr/subtitles/files/$pkgname-$pkgver.tgz \
	subtitles-pl.diff)
md5sums=('bb5282418f8b1bf8d47ac3d7c4b2ebb6'
         '9c5576dc5b1be1a40f7278e20c593fd5')

build() {
  cd $startdir/src/subtitles-$pkgver

  patch -Np1 -i $startdir/src/subtitles-pl.diff || return 1

  sed -i \
	 -e 's:-I$(VDRDIR)/include:-I$(VDRDIR):' \
	 -e 's:@cp $@ :install -D -m 755 $@ $(DESTDIR):' \
	 Makefile
  make VDRDIR=/usr/include/vdr LIBDIR=/usr/lib/vdr DESTDIR=$startdir/pkg all || return 1
}
